package 题目集.贪心.排序模拟;

import java.util.Arrays;
import java.util.Scanner;

public class 沙堡 {
    static int[] a;
    static int[] b;
    static int n,x,y;

    public static void main(String[] args) {
        Scanner sc=new Scanner(System.in);
        n = sc.nextInt();
        x=sc.nextInt();
        y=sc.nextInt();
        a=new int[n];
        b=new int[n];
        for (int i = 0; i < n; i++) {
            a[i]=sc.nextInt();
            b[i]=sc.nextInt();
        }
        Arrays.sort(a);
        Arrays.sort(b);
        long res=0;
        for (int i = 0; i < n; i++) {
            if (a[i]==b[i]) continue;
            if (a[i]<b[i]) {    //比预期矮
                res+=x*(b[i]-a[i]);
            }else {
                res+=y*(a[i]-b[i]);
            }
        }
        System.out.println(res);
    }

}
